/*
 * @Author: 余铖
 * @Date: 2020-03-31 10:04:48
 * @LastEditors: 余铖
 * @LastEditTime: 2020-03-31 11:45:59
 * @Description: API
 */

import axios from '@/libs/api.request';
import {
    getToken,
    URL
} from "@/libs/util";
// 以防命名冲突
const HOST = URL

export const requestData = ({ formData,url }) => {
    // console.log(formData, 'data222222222');
    let data = {};
    data['tokenEntity'] = {
        value: getToken()
    }
    data = Object.assign(data, formData);
    return axios.request({
        url: HOST + url,
        data,
        method: 'post'
    })
}
